Test automation systems are used to automatically test software-driven systems. Conventional architectures use a test harness, which is typically used to execute test cases, including test cases specified by attributes. The attributes are used to label classes or methods to mark which of the classes or methods should be examined for testing.
Conventional test harnesses operate on test cases specified by attributes by examining each of the labeled classes or methods, examining the attributes present, and then performing an action in response to the examined attributes. This method of using attributes requires that the code that is used to perform the action to be present in the test harness. Accordingly, a test harness must be modified (or written) to extend or create different test case formats used to test differing software applications or various hardware/software combinations that may be present in a system. Additionally, each automation system will also need to have its associated test harness modified if supporting the test format used by another automation system is desired.
Modifying or writing a test harness for different test case formats typically requires writing or modifying a non-trivial amount of code in each test harness so that the test harness can evaluate the test results. The implemented code for each test case format includes code to gather data about the test method being executed (e.g., test method description, test method attributes list, and the like), code to process the results from the attributes, and code that is used to determine the actual result of the test method.
In accordance with the present invention, a test harness can be reused without requiring modifications to run tests written using different test case formats.